﻿<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title>Easyui扩展库 当前位置 - 落阳 整理</title>
    <link href="http://www.easyui-extlib.com/Content/Site.css" rel="stylesheet" />
    <script src="http://www.easyui-extlib.com/Scripts/jquery/jquery-1.11.0.min.js"></script>
    <script src="http://www.easyui-extlib.com/Scripts/jquery-extensions/jquery.jdirk.js"></script>
    <link href="http://www.easyui-extlib.com/Scripts/jquery-easyui/jquery-easyui-1.4.3/themes/default/easyui.css" rel="stylesheet" />
    <link href="http://www.easyui-extlib.com/Scripts/jquery-easyui/jquery-easyui-1.4.3/themes/icon.css" rel="stylesheet" />
    <script src="http://www.easyui-extlib.com/Scripts/jquery-easyui/jquery-easyui-1.4.3/jquery.easyui.min.js"></script>
    <script src="http://www.easyui-extlib.com/Scripts/jquery-easyui/jquery-easyui-1.4.3/locale/easyui-lang-zh_CN.js"></script>
    <script src="http://www.easyui-extlib.com/Scripts/jquery-easyui-extensions/base/jeasyui.extensions.base.isEasyUI.js"></script>
    <script src="/Scripts/jquery-easyui-extensions/base/jeasyui.extensions.base.current.js"></script>
    <script>
        $(function () {

            var easyuiPlugins1 = [
                { value: "currentLayout", text: "当前laytou对象" },
                { value: "currentRegionPanel", text: "当前layout-region面板对象" },
                { value: "currentPanelRegion", text: "当前layout-region面板的region名称" },
                { value: "currentPanel", text: "当前penel对象" }
            ];

            $("#sel1").combobox({
                data: easyuiPlugins1,
                value: "currentLayout",
                width: 250
            });

            $("#btn1").click(function () {

                var method = $("#sel1").combobox("getValue"), pluginName = $("#sel1").combobox("getText");
                var current = $(this)[method]();
                var isJq = $.util.isJqueryObject(current), has = isJq && current.length > 0;
                var content = isJq ? (has ? "已" : "未") + "找到" + pluginName + "" + (has ? "，请用浏览器开发者工具（F12）在控制台查看该对象。" : "") : current;
                $("#span1").html(content);
                if (has) {
                    console.log(current);
                }
            });


            $("#btn0").click(function () {
                $("#w0").window("open");
            });

            var easyuiPlugins2 = [
                { value: "currentTabs", text: "当前tas对象" },
                { value: "currentTabPanel", text: "当前tabs-tab面板对象" },
                { value: "currentTabIndex", text: "当前tabs-tab面板的索引号" },
                { value: "currentPanel", text: "当前penel对象" }
            ];

            $("#sel2").combobox({
                data: easyuiPlugins2,
                value: "currentTabs",
                width: 250
            });

            $("#btn2").click(function () {

                var method = $("#sel2").combobox("getValue"), pluginName = $("#sel2").combobox("getText");
                var current = $(this)[method]();
                var isJq = $.util.isJqueryObject(current), has = isJq && current.length > 0;
                var content = isJq ? (has ? "已" : "未") + "找到" + pluginName + "" + (has ? "，请用浏览器开发者工具（F12）在控制台查看该对象。" : "") : current;
                $("#span2").html(content);
                if (has) {
                    console.log(current);
                }
            });






            var easyuiPlugins3 = [
                { value: "currentAccordion", text: "当前accordion对象" },
                { value: "currentAccPanel", text: "当前accordion-panel面板对象" },
                { value: "currentAccIndex", text: "当前accordion-panel面板的索引号" },
                { value: "currentPanel", text: "当前penel对象" }
            ];

            $("#sel3").combobox({
                data: easyuiPlugins3,
                value: "currentAccordion",
                width: 250
            });

            $("#btn3").click(function () {

                var method = $("#sel3").combobox("getValue"), pluginName = $("#sel3").combobox("getText");
                var current = $(this)[method]();
                var isJq = $.util.isJqueryObject(current), has = isJq && current.length > 0;
                var content = isJq ? (has ? "已" : "未") + "找到" + pluginName + "" + (has ? "，请用浏览器开发者工具（F12）在控制台查看该对象。" : "") : current;
                $("#span3").html(content);
                if (has) {
                    console.log(current);
                }
            });





            var easyuiPlugins4 = [
                { value: "currentWindow", text: "当前window对象" },
                { value: "currentPanel", text: "当前penel对象" }
            ];

            $("#sel4").combobox({
                data: easyuiPlugins4,
                value: "currentWindow",
                width: 250
            });

            $("#btn4").click(function () {

                var method = $("#sel4").combobox("getValue"), pluginName = $("#sel4").combobox("getText");
                var current = $(this)[method]();
                var isJq = $.util.isJqueryObject(current), has = isJq && current.length > 0;
                var content = isJq ? (has ? "已" : "未") + "找到" + pluginName + "" + (has ? "，请用浏览器开发者工具（F12）在控制台查看该对象。" : "") : current;
                $("#span4").html(content);
                if (has) {
                    console.log(current);
                }
            });

        });

    </script>
</head>
<body>
    <div class="easyui-layout" data-options="fit:true">
        <div data-options="region:'north',border:false,split:true,title:'北部'" style="height:150px;border-bottom-width:1px;padding:20px;">
            <a id="btn1" class="easyui-linkbutton" data-options="iconCls:'icon-add'">获取本按钮所在的</a>
            <input id="sel1" type="text" />
            <br /><br /><br />
            <span id="span1" style="color:red;font-weight:bold;"></span>
        </div>
        <div data-options="region:'west',border:false,split:true,title:'西部'" style="width: 500px; border-right-width: 1px; padding: 20px;">
            <div class="easyui-accordion" data-options="fit:true">
                <div data-options="title:'手风琴面板1'" style="padding:5px;">
                    手风琴面板1的内容<br /><br /><br />
                    <a id="btn3" class="easyui-linkbutton" data-options="iconCls:'icon-add'">获取本按钮所在的</a>
                    <input id="sel3" type="text" />
                    <br /><br /><br />
                    <span id="span3" style="color:red;font-weight:bold;"></span>
                </div>
                <div data-options="title:'手风琴面板2'" style="padding:5px;">
                    手风琴面板2的内容
                </div>
                <div data-options="title:'手风琴面板3'" style="padding:5px;">
                    手风琴面板3的内容
                </div>
            </div>
        </div>
        <div data-options="region:'center',border:false,split:true,title:'中间'" style="border-left-width: 1px; padding: 20px;">
            <div class="easyui-tabs" data-options="fit:true">
                <div data-options="title:'标签页1'" style="padding:5px;">
                    标签页1的内容<br /><br /><br />
                    <a id="btn2" class="easyui-linkbutton" data-options="iconCls:'icon-add'">获取本按钮所在的</a>
                    <input id="sel2" type="text" />
                    <br /><br /><br />
                    <span id="span2" style="color:red;font-weight:bold;"></span>
                    <br /><br /><br />
                    <br /><br /><br />
                    <a id="btn0" class="easyui-linkbutton" data-options="iconCls:'icon-add'">打开easyui-window</a>
                    <div id="w0" class="easyui-window" data-options="title:'新窗口1',closed:true" style="width:500px;height:350px;padding:10px;">
                        只因在人群中多看了你一眼，再也不能忘记你容颜。
                        <br /><br /><br />
                        <a id="btn4" class="easyui-linkbutton" data-options="iconCls:'icon-add'">获取本按钮所在的</a>
                        <input id="sel4" type="text" />
                        <br /><br /><br />
                        <span id="span4" style="color:red;font-weight:bold;"></span>
                    </div>
                </div>
                <div data-options="title:'标签页2'" style="padding:5px;">
                    标签页2的内容
                </div>
            </div>
        </div>
    </div>
</body>
</html>
